package cj.web.marriage.constants;

/**
 * 学历
 * @author Administrator
 *
 */
public enum EducationEnum {
	//学历（0初中,1高中,2大专,3本科,4硕士,5博士）
	NUM_0("初中",0),
	NUM_1("高中", 1),
	NUM_2("大专", 2),
	NUM_3("本科", 3),
	NUM_4("硕士", 4),
	NUM_5("博士", 5)
	;
    // 成员变量
    private String name;
    private int value;

    // 构造方法
    private EducationEnum(String name, int value) {
        this.name = name;
        this.value = value;
    }

    // 普通方法
    public static String getName(int value) {
        for (EducationEnum c : EducationEnum.values()) {
            if (c.getValue() == value) {
                return c.name;
            }
        }
        return null;
    }

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public int getValue() {
		return value;
	}

	public void setValue(int value) {
		this.value = value;
	}
}
